<script setup>
import { useI18n } from 'vue-i18n'

const { t } = useI18n()
</script>

<template>
  <section class="explore-china">
    <div class="explore-container">
      <h2 class="explore-title">探索中国</h2>
      <p class="explore-subtitle">这些热门目的地精彩纷呈</p>
      
      <div class="destination-grid">
        <!-- 故宫 -->
        <div class="destination-card">
          <div class="card-image">
            <img src="@/assets/home/explore1.jpg" alt="故宫">
            <button class="favorite-btn">
              <span class="heart-icon">♡</span>
            </button>
            <span class="duration-tag">2-3 天</span>
          </div>
          <div class="card-content">
            <h3 class="destination-title">故宫博物院</h3>
            <div class="location">
              <span class="location-icon">📍</span>
              <span>北京市东城区景山前街4号</span>
            </div>
            <p class="description">中国明清两代的皇家宫殿，世界上现存规模最大、保存最完整的木质结构古建筑群。穿行于近万间古建筑中，感受600年的皇家历史。</p>
            <div class="features">
              <span class="feature-tag">世界文化遗产</span>
              <span class="feature-tag">必游景点</span>
            </div>
            <div class="rating">
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
            </div>
            <div class="price">
              <span class="current-price">¥120</span>
              <span class="original-price">¥160</span>
            </div>
          </div>
        </div>

        <!-- 外滩 -->
        <div class="destination-card">
          <div class="card-image">
            <img src="@/assets/home/explore2.jpg" alt="外滩">
            <button class="favorite-btn">
              <span class="heart-icon">♡</span>
            </button>
            <span class="duration-tag">1-2 天</span>
          </div>
          <div class="card-content">
            <h3 class="destination-title">外滩夜景</h3>
            <div class="location">
              <span class="location-icon">📍</span>
              <span>上海市黄浦区中山东一路</span>
            </div>
            <p class="description">被誉为"万国建筑博览群"的外滩，汇集了各种风格的经典建筑，夜幕降临后的璀璨灯光秀更是不容错过的视觉盛宴。</p>
            <div class="features">
              <span class="feature-tag">网红打卡</span>
              <span class="feature-tag">夜景推荐</span>
            </div>
            <div class="rating">
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
            </div>
            <div class="price">
              <span class="current-price">免费</span>
            </div>
          </div>
        </div>

        <!-- 陆家嘴 -->
        <div class="destination-card">
          <div class="card-image">
            <img src="@/assets/home/explore5.jpg" alt="重庆洪崖洞">
            <button class="favorite-btn">
              <span class="heart-icon">♡</span>
            </button>
            <span class="duration-tag">2-3 小时</span>
          </div>
          <div class="card-content">
            <h3 class="destination-title">重庆洪崖洞</h3>
            <div class="location">
              <span class="location-icon">📍</span>
              <span>重庆市渝中区解放碑沧白路88号</span>
            </div>
            <p class="description">依山就势而建的"山城明珠"，集观光、餐饮、休闲于一体的立体式建筑群。夜幕降临后灯火通明，是重庆夜景最精华的代表。</p>
            <div class="features">
              <span class="feature-tag">网红地标</span>
              <span class="feature-tag">美食天堂</span>
            </div>
            <div class="rating">
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
            </div>
            <div class="price">
              <span class="current-price">免费</span>
            </div>
          </div>
        </div>

        <!-- 橘子洲 -->
        <div class="destination-card">
          <div class="card-image">
            <img src="@/assets/home/explore4.jpg" alt="橘子洲">
            <button class="favorite-btn">
              <span class="heart-icon">♡</span>
            </button>
            <span class="duration-tag">半天</span>
          </div>
          <div class="card-content">
            <h3 class="destination-title">橘子洲头</h3>
            <div class="location">
              <span class="location-icon">📍</span>
              <span>湖南省长沙市岳麓区</span>
            </div>
            <p class="description">湘江中的地标性景区，青年毛泽东诗词《沁园春·长沙》的创作地。漫步于洲岛之上，感受诗意长沙，欣赏湘江两岸风光。</p>
            <div class="features">
              <span class="feature-tag">人文景观</span>
              <span class="feature-tag">诗词圣地</span>
            </div>
            <div class="rating">
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
              <span class="star">★</span>
            </div>
            <div class="price">
              <span class="current-price">¥80</span>
              <span class="original-price">¥100</span>
            </div>
          </div>
        </div>
      </div>

      <div class="navigation-buttons">
        <button class="nav-btn prev">←</button>
        <button class="nav-btn next">→</button>
      </div>
    </div>
  </section>
</template>

<style scoped>
/* 探索中国区域样式 */
.explore-china {
  padding: 60px 152px;
  background-color: #ffffff;
  height: 938px;
}

.explore-container {
  max-width: 1296px;
  margin: 0 auto;
  padding: 0;
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.explore-title {
  font-size: 2.5rem;
  font-weight: bold;
  color: #333;
  margin-bottom: 16px;
}

.explore-subtitle {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 40px;
}

.destination-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 40px;
  width: 1296px;
  height: 596px;
}

.destination-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
  height: 100%;
}

.destination-card:hover {
  transform: translateY(-5px);
}

.card-image {
  position: relative;
  width: 100%;
  padding-top: 66%;
}

.card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.favorite-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.favorite-btn:hover {
  background: #fff;
  transform: scale(1.1);
}

.heart-icon {
  font-size: 16px;
  color: #ff5a5a;
}

.duration-tag {
  position: absolute;
  left: 12px;
  top: 12px;
  background: rgba(0, 195, 137, 0.9);
  color: white;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
}

.card-content {
  padding: 15px;
}

.destination-title {
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 8px;
  color: #333;
}

.location {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #666;
  font-size: 0.8rem;
  margin-bottom: 8px;
}

.location-icon {
  color: #00c389;
}

.rating {
  margin-bottom: 8px;
}

.star {
  color: #ffcc33;
  font-size: 0.9rem;
}

.price {
  display: flex;
  align-items: center;
  gap: 10px;
}

.current-price {
  font-size: 1.2rem;
  font-weight: bold;
  color: #333;
}

.original-price {
  font-size: 0.9rem;
  color: #999;
  text-decoration: line-through;
}

.navigation-buttons {
  position: absolute;
  top: 0;
  right: 20px;
  display: flex;
  gap: 10px;
}

.nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #e0e0e0;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.nav-btn:hover {
  background: #f5f5f5;
  border-color: #ccc;
}

/* 响应式样式 */
@media (max-width: 1200px) {
  .explore-china {
    height: auto;
    min-height: 938px;
    padding: 60px 40px;
  }
  
  .explore-container {
    padding-left: 0;
    padding-right: 0;
  }
  
  .destination-grid {
    width: 100%;
    height: auto;
    min-height: 596px;
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 992px) {
  .explore-china {
    height: auto;
    min-height: 938px;
    padding: 60px 30px;
  }
  
  .explore-container {
    padding-left: 0;
    padding-right: 0;
  }
  
  .destination-grid {
    width: 100%;
    height: auto;
    min-height: 596px;
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .explore-china {
    height: auto;
    min-height: 938px;
    padding: 50px 30px;
  }
  
  .explore-title {
    font-size: 2rem;
  }
  
  .explore-subtitle {
    font-size: 1rem;
  }
  
  .destination-grid {
    gap: 20px;
  }
}

@media (max-width: 576px) {
  .explore-china {
    height: auto;
    min-height: 938px;
    padding: 40px 20px;
  }
  
  .explore-container {
    padding-left: 0;
    padding-right: 0;
  }
  
  .destination-grid {
    width: 100%;
    height: auto;
    min-height: 596px;
    grid-template-columns: repeat(1, 1fr);
  }
  
  .navigation-buttons {
    position: static;
    justify-content: center;
    margin-top: 20px;
  }
}

.description {
  font-size: 0.9rem;
  color: #666;
  margin: 12px 0;
  line-height: 1.5;
}

.features {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.feature-tag {
  background-color: #f0f9ff;
  color: #0369a1;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
}
</style> 